<template>
  <div>
    <div class="wb">
        <div class="wStop w">
            <div class="wStopImg">
                <img @click="goBack()" src="../../../assets/imgs/logo.png" alt="图"/>
            </div>
            <div class="wStopList clearfix" >
                <template v-for="(ins1,v1) in warr1">
                    <div :key="v1"  @click="wSchang(v1)">
                        <span :class="ads==v1?'wStop-col':''">{{ins1}}<i v-show="v1!=0" ></i></span>
                    </div>
                </template>
            </div>
        </div>
    </div>
  </div>
</template>

<script>
export default {
    name:'ShopNav',
    data(){
        return{
            warr1:this.$store.state.wly[0].warr1,
            ads:this.$store.state.wly[0].ads,
            //  warr1: ['订单提交成功', '确认订单信息', '我的购物车'],
            //  ads: '2',
        }
    },
    mounted(){
    },
    methods:{
        wSchang(v1){
            console.log(v1);
            if(v1==0){
                // this.$store.state.wly[0].ads=0;
                // this.ads=0;
                this.$router.replace('/shopThree');
            }
            if(v1==1){
                //  this.$store.state.wly[0].ads=1;
                // this.ads=1;
                this.$router.replace('/shopTwo');
            }if(v1==2){
                //  this.$store.state.wly[0].ads=2;
                // this.ads=2;
                this.$router.replace('/shop');
            }
        }, goBack(){
            this.$router.replace('/');
        },       
    }

}
</script>

<style scoped>
/* public */
.w{
    width: 1280px;
    margin: 0 auto;
}
.wb{
    width: 100%;
   border-bottom: 1px solid #ddd;
}
/*  */
.wStop{
   height: 95px;
   overflow: hidden;
   display: flex;
   padding-bottom: 37px;
}
.wStopImg{
    margin-top: 25px;
    text-align: left;
    width: 376px;
    background-color: #fff;
}
.wStopList{
    width: 904px;
    height: 95px;
    font-size: 16px;
    text-align: right;
    position: relative;
}
.wStopList div{
    float: right;
    line-height: 38px;
    padding-top:56px ;
}
.wStopList div i{
    display: inline-block;
    height: 17px;
    width: 10px;
    position: relative;
    top: 3px;
    margin: 0 40px;
     background: url(../../../assets/imgs/w-jian.png) no-repeat 0 0;
}
.wStopList div span{
    color: #333;
    cursor: pointer;
}
.wStopList div .wStop-col{
    color: #f08200;
}

.clearfix::after{
    content: '';
    height: 0;
    display: block;
    visibility: hidden;
    clear: both;
}
.clearfix{
    *zoom: 1;
}
</style>